package com.supms.course.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.supms.course.mapper.TestReviewMistakeMapper;
import com.supms.course.domain.TestReviewMistake;
import com.supms.course.service.ITestReviewMistakeService;

/**
 * 复查成绩错误登记Service业务层处理
 * 
 * @author LiangHao
 * @date 2022-03-10
 */
@Service
public class TestReviewMistakeServiceImpl implements ITestReviewMistakeService 
{
    @Autowired
    private TestReviewMistakeMapper testReviewMistakeMapper;

    /**
     * 查询复查成绩错误登记
     * 
     * @param id 复查成绩错误登记主键
     * @return 复查成绩错误登记
     */
    @Override
    public TestReviewMistake selectTestReviewMistakeById(Long id)
    {
        return testReviewMistakeMapper.selectTestReviewMistakeById(id);
    }

    /**
     * 查询复查成绩错误登记列表
     * 
     * @param testReviewMistake 复查成绩错误登记
     * @return 复查成绩错误登记
     */
    @Override
    public List<TestReviewMistake> selectTestReviewMistakeList(TestReviewMistake testReviewMistake)
    {
        return testReviewMistakeMapper.selectTestReviewMistakeList(testReviewMistake);
    }

    /**
     * 新增复查成绩错误登记
     * 
     * @param testReviewMistake 复查成绩错误登记
     * @return 结果
     */
    @Override
    public int insertTestReviewMistake(TestReviewMistake testReviewMistake)
    {
        testReviewMistake.setCreateTime(DateUtils.getNowDate());
        return testReviewMistakeMapper.insertTestReviewMistake(testReviewMistake);
    }

    /**
     * 修改复查成绩错误登记
     * 
     * @param testReviewMistake 复查成绩错误登记
     * @return 结果
     */
    @Override
    public int updateTestReviewMistake(TestReviewMistake testReviewMistake)
    {
        testReviewMistake.setUpdateTime(DateUtils.getNowDate());
        return testReviewMistakeMapper.updateTestReviewMistake(testReviewMistake);
    }

    /**
     * 批量删除复查成绩错误登记
     * 
     * @param ids 需要删除的复查成绩错误登记主键
     * @return 结果
     */
    @Override
    public int deleteTestReviewMistakeByIds(Long[] ids)
    {
        return testReviewMistakeMapper.deleteTestReviewMistakeByIds(ids);
    }

    /**
     * 删除复查成绩错误登记信息
     * 
     * @param id 复查成绩错误登记主键
     * @return 结果
     */
    @Override
    public int deleteTestReviewMistakeById(Long id)
    {
        return testReviewMistakeMapper.deleteTestReviewMistakeById(id);
    }
}
